class AutoCoursesController < ApplicationController
  layout "main"
  before_filter :pre_session
  active_scaffold :auto_course do |config|
    config.label = '<br/>'
    config.list.per_page = 10
    config.actions = [:search, :list, :update, :create, :show]
    config.columns = [:id, :name]
  end

  def pre_session
    if !isadmin?
      redirect_to :controller=>"main"
    end
  end
end
